package com.ruoyi.yuwen.domain;

import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 订单对象 t_order
 * 
 * @author ruoyi
 * @date 2023-02-27
 */
@Data
public class Order extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 主键 */
    private Long id;

    /** 订单号 */
    @Excel(name = "订单号")
    private String orderOn;

    /** 订单状态（0：审核中，1：已驳回，2：已过审，3：已激活） */
    @Excel(name = "订单状态", readConverterExp = "0=：审核中，1：已驳回，2：已过审，3：已激活")
    private Integer state;

    /** 图片地址 */
    @Excel(name = "图片地址")
    private String picture;

    /** 用户id */
    @Excel(name = "用户id")
    private Long userId;

    /** 用户名 */
    @Excel(name = "用户名")
    private String userName;

    /** 上级id */
    @Excel(name = "上级id")
    private Long fatherId;

    /** 数量 */
    @Excel(name = "数量")
    private Long num;

    /** 联系电话 */
    @Excel(name = "联系电话")
    private String phone;

    /** 创建时间 */
    @Excel(name = "创建时间")
    private String addTime;

    /** 驳回原因 */
    @Excel(name = "驳回原因")
    private String reason;

    /** 库存增减数量 */
    @Excel(name = "库存增减数量")
    private String changeNum;

    /** 商品id */
    @Excel(name = "商品id")
    private Long goodsId;

    /** 商品名称 */
    @Excel(name = "商品名称")
    private String goodsName;

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("orderOn", getOrderOn())
            .append("state", getState())
            .append("picture", getPicture())
            .append("userId", getUserId())
            .append("userName", getUserName())
            .append("fatherId", getFatherId())
            .append("num", getNum())
            .append("phone", getPhone())
            .append("addTime", getAddTime())
            .append("reason", getReason())
            .append("changeNum", getChangeNum())
            .append("goodsId", getGoodsId())
            .append("goodsName", getGoodsName())
            .toString();
    }
}
